package com.book.manager.dao;

import java.util.List;

import com.book.entity.Manager;

public class BookDaoService {
	BookDao bd = new BookDao();
	public Manager findManager (int id) {
		Manager m = bd.findManagerById(id);
		return m;
	}
	public boolean AddManager (Manager m) {
		if(!bd.isExist((m.getMid()))){
			bd.addManager(m);
			return true;
		}else{
			System.out.println("此书籍已存在");
			return false;
		}
	}
	public List<Manager> findAll() {
		List<Manager> list=bd.findAll();
		return list;
	}
}
